<?php
/**
 * Created by PhpStorm.
 * User: dell
 * Date: 2018/11/1
 * Time: 8:08
 */

$file_name = 'two.html';

if(file_exists($file_name) && filemtime($file_name)-time() <10)
{
    require_once($file_name);
}
else
{
    ob_start();
}

?>

    <!doctype html>
    <html lang="en">
    <head>
        <meta charset="UTF-8">
        <title>Document</title>
    </head>
    <body>
    <center>
        <table>
            <tr>
                <td>姓名</td>
                <td><input type="text"/></td>
            </tr>
            <tr>
                <td>性别</td>
                <td>
                    <input type="radio"/>男
                    <input type="radio"/>女
                </td>
            </tr>
            <tr>
                <td>年龄</td>
                <td><input type="text"/></td>
            </tr>
            <tr>
                <td>籍贯</td>
                <td><input type="text"/></td>
            </tr>
            <tr>
                <td><input type="submit" value="提交"/></td>
                <td></td>
            </tr>
        </table>
    </center>
    </body>
    </html>

    <h2>还是有一点问题啊   觉得哪里不对</h2>

<?php

file_put_contents($file_name,ob_get_contents());
